FusionAuth
    • Home
    • Categories
    • Recent
    • Popular
    • Pricing
    • Contact us
    • Docs
    • Login
    1. Home
    2. Tags
    3. java client
    Log in to post
    • All categories
    • danD

      Are the post and get forms of the user search API equivalent?

      Q&A
      • database user search java client • • dan
      2
      0
      Votes
      2
      Posts
      2.5k
      Views

      danD

      Yes, they are equivalent. Building this JSON:

      { "search": { "queryString": "fusionauth.io" } }

      and posting it is equivalent to a GET with queryString=fusionauth.io.

    • danD

      Searching for users with the java client

      Q&A
      • java client search users • • dan
      2
      0
      Votes
      2
      Posts
      5.4k
      Views

      danD

      Looking at https://github.com/FusionAuth/fusionauth-java-client/blob/master/src/main/java/io/fusionauth/client/FusionAuthClient.java#L3256

      It appears there is no way to search using the Java client that uses a GET, only a POST. However, you can still provide the queryString in the JSON and it will be equivalent to the GET request.

      Building this JSON:

      { "search": { "queryString": "fusionauth.io" } }

      Is equivalent to queryString=fusionauth.io.

      Hope that helps.

    • danD

      Patching the user object with the java client?

      Q&A
      • patch user java client • • dan
      2
      0
      Votes
      2
      Posts
      1.2k
      Views

      danD

      I see patchUser here:

      https://github.com/FusionAuth/fusionauth-java-client/blob/1.19.0/src/main/java/io/fusionauth/client/FusionAuthClient.java#L1664

      I think that's what you want.

      You can, however, always full retrieval and a put as a workaround. That is recommended if you are changing an array, unless you want the behavior documented here: https://github.com/FusionAuth/fusionauth-issues/issues/441